package login;

import android.os.Handler;

import basemvp.MyCallBack;

/**
 * Created by Gao on 2019/1/31.
 */

public class MyModle {

    public static void getNetData(final String param, final MyCallBack<String> callBack) {
        new Handler().postDelayed(new Runnable() {
            @Override
            public void run() {
                switch (param) {
                    case "0":
                        callBack.onSuccess("成功");
                        break;
                    case "1":
                        callBack.onFailure("失败");
                        break;
                }
                callBack.onComplete();
            }
        }, 2000);
    }
}
